package com.jiaai.web.zfp_back.system;

import com.alibaba.dubbo.config.annotation.Reference;
import com.jiaai.exception.ServerException;
import com.jiaai.system.api.ISystemCacheManage;
import com.jiaai.util.RestResultGenerator;

import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * Created by Administrator on 2018\3\23 0023.
 */
@RequestMapping("/api/v1/admin/manage")
@RestController
public class AdminSystemMangeController {
    @Reference
    private ISystemCacheManage systemCacheManage;

    @RequestMapping("/rebuildCache")
    public  Object rebuildCache()throws ServerException{
        systemCacheManage.rebuildCache();
        return RestResultGenerator.genSuccessResult();
    }
}
